module.exports = app => {
    const { router, controller } = app;
    router.get('/list', controller.home.getList);
    router.get('/live', controller.home.getLive);
    router.get('/grop', controller.home.getGrop);
    router.post('/addList',controller.home.addList)
    router.post('/addGrop',controller.home.addGrop)
    router.put('/editList',controller.home.editList)
    router.put('/editGrop',controller.home.editGrop)
    router.delete('/delList/:id',controller.home.delList)
    router.delete('/delLive/:id',controller.home.delLive)
    router.delete('/delGrop/:id',controller.home.delGrop)
    router.post('/detail/:id',controller.home.detailId)
    router.get("/search", controller.home.Search)
    router.get('/switchLive', controller.home.switchLive)

    router.post('/login',controller.user.login)
    router.post('/register',controller.user.register)

    router.get('/audit', controller.page.getAudit)
    router.get('/orders', controller.page.getOrder);
    router.put('/editAudit',controller.page.editAudit)
    router.delete('/audit/:id',controller.page.delAudit)
    router.get("/searchAudit", controller.page.searchAudit);
    router.delete('/orders/:id',controller.page.delOrder)
    router.get('/switchAudit', controller.page.switchAudit)
    router.get('/switchOrder', controller.page.switchOrder)
    router.get('/switchGrop', controller.page.switchGrop)

    router.get('/news', controller.news.getNews);
    router.post('/addNews',controller.news.addNews)
    router.put('/editNews',controller.news.editNews)
    router.delete('/delNews/:id',controller.news.delNews)

    router.get('/people', controller.people.getPeo);
    router.post('/addPeo',controller.people.addPeo)
    router.put('/editPeo',controller.people.editPeo)
    router.delete('/delPeo/:id',controller.people.delPeo)
    router.get('/switchBroker', controller.people.switchBroker)
}